<%@ page pageEncoding="UTF-8"%>

<%@ taglib uri="/tags/struts-tiles" prefix="tiles"%>
<%@ taglib uri="/tags/struts-html" prefix="html"%>
<%@ taglib uri="/tags/struts-logic" prefix="logic"%>
<%@ taglib uri="/tags/struts-nested" prefix="nested"%>
<%@ taglib uri="/tags/struts-bean" prefix="bean"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix='fmt'%>
<%@ taglib uri="/tags/trymore" prefix="tm"%>

<script type="text/javascript">
	function callback_groupRemove(id) {
		if ($("#group-" + id).size() > 0) {
			$("#group-" + id).fadeOut("slow");
		}
	}
</script>

<div id="group_wrapper">
	<form id="pagerForm" method="post" action="app/system/group.do?action=pageGroupIndex">
		<input type="hidden" name="pageNum" value="${pagingBean ne null ? pagingBean.currentPage : 1}" />
		<input type="hidden" name="numPerPage" value="${pagingBean ne null ? pagingBean.pageSize : 20}" />
	</form>
	
	<!-- SearchBar -->
	<div class="pageHeader">
		<form onsubmit="return navTabSearch(this);" action="app/system/group.do?action=pageGroupIndex" 
			method="post" id="searchForm" rel="pagerForm">
			<div class="searchBar">
				<table class="searchContent">
					<tr>
						<td>
							<label>项目组名：</label>
							<input type="text" name="groupName" rel="pagerForm" value="${groupName ne null ? groupName : ''}" />
						</td>
						<td>
							<label>项目组长：</label>
							<input id="groupLeader" type="text" name="gleader.username" rel="pagerForm" value="${groupLeader ne null ? groupLeader : ''}" postField="search" 
								suggestFields="username,userNo" suggestUrl="app/base.do?action=lookupUserByName" lookupGroup="gleader" />
						</td>
						<td>
							<label>项目成员：</label>
							<input id="groupMember" type="text" name="gmember.username" rel="pagerForm" value="${groupMember ne null ? groupMember : ''}" postField="search" 
								suggestFields="username,userNo" suggestUrl="app/base.do?action=lookupUserByName" lookupGroup="gmember" />
						</td>
					</tr>
				</table>
				<div class="subBar">
					<ul>
						<li><div class="buttonActive"><div class="buttonContent"><button type="submit">检索</button></div></div></li>
					</ul>
				</div>
			</div>
		</form>
	</div>
	
	<!-- Body -->	
	<div class="pageContent">
		<div class="panelBar">
			<ul class="toolBar">
				<li>
					<a class="add" href="app/system/group.do?action=dialogGroupPage" 
						target="dialog" title="添加新项目组" mask="true" width="554" height="370" rel="dia_sys_groupadd">
						<span>添加新项目组</span>
					</a>
				</li>
			</ul>
		</div>
		
		<%@ include file="datagrid/dataGridGroup.jsp" %>
		
	</div>
</div>